﻿using System;
using System.Collections.Generic;
using System.Text;
using UnityEngine;

namespace ProjScan.RecordManager.AssetData
{
	// Token: 0x0200029C RID: 668
	internal class LODAssetData : ComponentAssetData<LODGroup>
	{
		// Token: 0x0600116E RID: 4462 RVA: 0x000521E0 File Offset: 0x000503E0
		public LODAssetData(int id, LODGroup lodGroup, string name) : base(id, name, lodGroup)
		{
			this.missingLevels = new List<int>();
			this.lods = lodGroup.GetLODs();
			bool flag = this.lods == null;
			if (flag)
			{
				this.lodCount = 0;
			}
			else
			{
				this.lodCount = this.lods.Length;
			}
		}

		// Token: 0x0600116F RID: 4463 RVA: 0x00052238 File Offset: 0x00050438
		public override string GetCSVHeader()
		{
			return "Name,DirID,LODCnt,MissingLvl";
		}

		// Token: 0x06001170 RID: 4464 RVA: 0x00052250 File Offset: 0x00050450
		public override string GetInfo()
		{
			StringBuilder stringBuilder = new StringBuilder();
			stringBuilder.Append(this.name);
			stringBuilder.Append(',');
			stringBuilder.Append(this.directoryId);
			stringBuilder.Append(',');
			stringBuilder.Append(this.lodCount);
			stringBuilder.Append(',');
			bool flag = this.missingLevels.Count == 0;
			if (flag)
			{
				stringBuilder.Append('(').Append(')');
			}
			else
			{
				foreach (int value in this.missingLevels)
				{
					stringBuilder.Append('(').Append(value).Append(')');
				}
			}
			return stringBuilder.ToString();
		}

		// Token: 0x06001171 RID: 4465 RVA: 0x00008623 File Offset: 0x00006823
		public override void Reset()
		{
			this.component = null;
			this.lods = null;
		}

		// Token: 0x04000A2C RID: 2604
		public int lodCount;

		// Token: 0x04000A2D RID: 2605
		public List<int> missingLevels;

		// Token: 0x04000A2E RID: 2606
		public LOD[] lods;
	}
}
